<?php 
defined('_JEXEC') or die('Restricted access'); 

require(dirname(__FILE__).DS.'helper.php'); 

$random = $params->get('random', 0);
$finalist =$params->get('finalist', 0);
$title = $params->get('moduletitle', '');
$document =& JFactory::getDocument();
$css =JURI::base() .'modules/mod_sketchup/assets/css/mod_sketchup.css';
$document ->addStyleSheet ($css);

if($random)
{
	$list = modSketchupHelper::getRandomSketchups($params);
}

if($finalist)
{
	$list = modSketchupHelper::getFinalistSketchups($params);
}
else
{
	$list = modSketchupHelper::getSketchups($params);
}

if (count($list)) {
	require(JModuleHelper::getLayoutPath('mod_sketchup', 'default'));
}

?> 

